package requset

import "time"

type PageInfo struct {
	Page     int64 `json:"page" validate:"required,number"`     // 显示第几页
	PageSize int64 `json:"pageSize" validate:"required,number"` //一页显示多少
}
type SearchWithPage[T any] struct {
	PageInfo PageInfo `json:"pageInfo"`
	Data     T        `json:"data"`
}
type SearchWithTime struct {
	StartTime time.Time `json:"startTime,omitempty" `
	EndTime   time.Time `json:"endTime,omitempty"`
}
type PageResult[T any] struct {
	Total int64 `json:"total"`
	Items []*T  `json:"items"`
}
type UpdateBy[D, T any] struct {
	Where  D `json:"where"`
	Target T `json:"target"`
}
